package sicnu.cs.ich.api.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;

/**
 * @author 黎琦
 * @date 2021-11-27 20:18
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("t_activity_participate")
public class ActivityParticipate implements Serializable {

  @NotNull(message = "活动id不能为空")
  private Integer activityId;
  @NotNull(message = "参与者id不能为空")
  private Integer userId;
  /**
   * 参与者状态，1：审核通过，0：待审核，-1：审核不通过or号召失效or取消号召
   */
  @NotNull(message = "参与者状态status不能为空")
  private Integer status;
  @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
  @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  private Date createTime;
}
